package com.wish.g04.financing.controller;

import com.wish.g04.base.entity.CwCheckBatch;
import com.wish.g04.common.core.web.controller.BaseController;
import com.wish.g04.common.core.web.page.TableDataInfo;
import com.wish.g04.financing.dto.CheckBatchDTO;
import com.wish.g04.financing.service.CheckBatchService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * 对账批次
 * @author tyd
 * @since 2022-05-28
 */
@RestController
@RequestMapping("/batch")
public class CheckBatchController extends BaseController {

    @Autowired
    private CheckBatchService checkBatchService;

    /**
     * 对账批次查询
     * @param checkBatchDTO
     * @return
     */
    @GetMapping("getCheckBatchList")
    public TableDataInfo getCheckBatchList(CheckBatchDTO checkBatchDTO) {
        startPage();
        List<CwCheckBatch> cwCheckBatchList = checkBatchService.getCheckBatchList(checkBatchDTO);
        return getDataTable(cwCheckBatchList);
    }

}
